﻿using System;

namespace DO.DreamOnTrader
{
	/// <summary>
	/// 交易商品集合
	/// </summary>
	static public class ProductSet
	{
		/// <summary>
		/// 大台指
		/// </summary>
		public static Product TX = new Product("TX", 200, 80, 0.00004f, 70000, "FITX");

		/// <summary>
		/// 小台指
		/// </summary>
		public static Product MTX = new Product("MTX", 50, 35, 0.00004f, 30000, "FIMTX");


		/// <summary>
		/// 將商品代碼轉為 Product類別
		/// </summary>
		/// <param name="productName">商品代碼</param>
		/// <returns></returns>
		static public Product parse(string productName)
		{
			switch (productName)
			{
				case "TX": return TX;
				case "MTX": return MTX;
				default:
					return null;
			}
		}
	}
}
